package com.example.hello.client.ButtonGroup;

import com.vaadin.shared.AbstractComponentState;
import com.vaadin.shared.Connector;

import java.util.LinkedList;
import java.util.List;

public class BootstrapButtonGroupState extends AbstractComponentState {

    private List<Connector> buttons = new LinkedList<Connector>();

    private String toggle = "NONE";
    private boolean vertical = false;

    public void addButton(Connector button) {
        buttons.add(button);
    }

    public void addButton(Connector button, int index) {
        buttons.add(index, button);
    }

    public void removeButton(Connector button) {
        buttons.remove(button);
    }

    public List<Connector> getButtons() {
        return buttons;
    }

    public void setButtons(List<Connector> buttons) {
        this.buttons = buttons;
    }

    public boolean isVertical() {
        return vertical;
    }

    public void setVertical(boolean vertical) {
        this.vertical = vertical;
    }

    public String getToggle() {
        return toggle;
    }

    public void setToggle(String toggle) {
        this.toggle = toggle;
    }
}